#ifndef HBDATAHANDLER_H
#define HBDATAHANDLER_H
#include <QtXml>
#include "cexception.h"

namespace Diablo3{
    enum DOCTYPES{
        CHARACTER,
        ABILITIES
        //GEAR
    };

    QString DOCTYPEString(DOCTYPES);
}

class HBDataHandler
{
    Q_DECLARE_TR_FUNCTIONS(HBDataHandler)
public:
    HBDataHandler(QString filePath,Diablo3::DOCTYPES docType,QString name);
    QDomDocument& getDoc();
    void setFilePath(QString path);
    void save();
    void load();
private:
    QDomDocument doc;
    QString filePath;
};

#endif // HBDATAHANDLER_H
